package com.example.permissionsystem1_1.businessFunction.dao.repository;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.example.permissionsystem1_1.businessFunction.dao.entity.po.DepartmentInfoPo;
import com.example.permissionsystem1_1.businessFunction.dao.entity.po.DepartmentUserPo;
import com.example.permissionsystem1_1.businessFunction.dao.entity.po.TestPo;
import com.example.permissionsystem1_1.common.businessFunction.BaseDao;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

@Mapper
public interface DepartmentUserDao extends BaseDao<DepartmentUserPo> {

    /**
     * 批量新增多条记录
     * @param pos
     * @return
     */
    int insertBatch(@Param("pos")List<DepartmentUserPo> pos);
    /**
     * 根据给定的字段值删除符合条件的多条记录
     * @param po
     * @return
     */
    int deletes(@Param("po")DepartmentUserPo po);
    //************************\\

    /**
     * 根据用户id查询全部部门信息
     * @param userId
     * @return
     */
    List<DepartmentUserPo> selectAllDepartmentsByUserId(@Param("userId")Long userId);



}
